package Observer.Stock;

public class StockCommon extends AbstractStockPrice{

    public StockCommon(String code)
    {
        super(code);
    }

    @Override
    protected void notifyHolder() {
        System.out.println("普通股票更新了-" + code + ":" + "原价:" + oldPrice + "-现价:" + price);
        for(IStockHolder ish:stockHolderList)
        {
            ish.update(this);
        }
        oldPrice = price;
    }
}
